The purpose of this presentation is to show how to create a 3d interactive graph with the package plotly
- First we prepare the data
- Then we will create a 3d scatter plot
30 aprile 2019
The purpose of this presentation is to show how to create a 3d interactive graph with the package plotly
First we load the dataset airquality and exlude the raw with no information about variables we will use in the graph
data(airquality) airquality <- airquality[complete.cases(airquality[,1:4]),] str(airquality)
## 'data.frame': 111 obs. of 6 variables: ## $ Ozone : int 41 36 12 18 23 19 8 16 11 14 ... ## $ Solar.R: int 190 118 149 313 299 99 19 256 290 274 ... ## $ Wind : num 7.4 8 12.6 11.5 8.6 13.8 20.1 9.7 9.2 10.9 ... ## $ Temp : int 67 72 74 62 65 59 61 69 66 68 ... ## $ Month : int 5 5 5 5 5 5 5 5 5 5 ... ## $ Day : int 1 2 3 4 7 8 9 12 13 14 ...